DBHDCeff Function

private function DBHDCeff(dbhdcmin, dbhdcmax, den, denmin, denmax) result(dbhdc)

Compute the actual ratio DBH-crown diameter: crown/dbh (m/cm)

Arguments

Type IntentOptional Attributes Name
real(kind=float), intent(in) :: dbhdcmin

minimum ratio between stem and crown diameters (m/cm)

real(kind=float), intent(in) :: dbhdcmax

maximum ratio between stem and crown diameters (m/cm)

real(kind=float), intent(in) :: den

current tree density (trees/ha)

real(kind=float), intent(in) :: denmin

minimum tree density (trees/ha)

real(kind=float), intent(in) :: denmax

minimum tree density (trees/ha)

Return Value real(kind=float)

returned result


Source Code

FUNCTION  DBHDCeff &
!
(dbhdcmin, dbhdcmax, den, denmin, denmax) &
!
RESULT (dbhdc)

IMPLICIT NONE

!arguments with intent(in):
REAL (KIND = float), INTENT(IN) :: dbhdcmin !! minimum ratio between stem and crown diameters (m/cm)
REAL (KIND = float), INTENT(IN) :: dbhdcmax !! maximum ratio between stem and crown diameters (m/cm)
REAL (KIND = float), INTENT(IN) :: den !! current tree density (trees/ha)
REAL (KIND = float), INTENT(IN) :: denmin !! minimum tree density (trees/ha)
REAL (KIND = float), INTENT(IN) :: denmax !! minimum tree density (trees/ha)

!local declarations:
REAL (KIND = float) :: dbhdc !! returned result


!-----------------------------------end of declarations------------------------

dbhdc = ( dbhdcmax - dbhdcmin ) / ( denmax - denmin ) * &
           ( den - denmin ) + dbhdcmin

RETURN
END FUNCTION DBHDCeff